﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows.Controls;
using System.Windows;

namespace MovieRental_Presentation.Helpers
{
    public static class ValidationHelper
    {
        public static bool Validate(this Control c)
        {
            if (System.Windows.Controls.Validation.GetHasError(c))
            {
                c.Focus();
                return false;
            }
            return true;
        }
    }
}
